﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace BSC_OTC_Management.Forms
{
    public partial class FrmPhanBoLenhMua : Form
    {
        #region khai bao bien
        Code.PhanBoLenhMua _code = new Code.PhanBoLenhMua();
        AutoCompleteStringCollection autoCompleteDSCK = new AutoCompleteStringCollection();
        #endregion

        public FrmPhanBoLenhMua()
        {
            InitializeComponent();
            HienThiGiaoDien();
            this.txtMaCK.CharacterCasing = CharacterCasing.Upper;
        }

        private void HienThiGiaoDien()
        {
            ShowDS_MA_CK();
        }

        private void ShowDS_MA_CK()
        {
            this.txtMaCK.AutoCompleteMode = AutoCompleteMode.SuggestAppend;
            this.txtMaCK.AutoCompleteSource = AutoCompleteSource.CustomSource;
            foreach (DataRow row in this._code._tableDS_CK.Rows)
            {
                autoCompleteDSCK.Add(row["symbol"].ToString());
            }
            this.txtMaCK.AutoCompleteCustomSource = autoCompleteDSCK;
        }
    }
}
